-
Notifications
You must be signed in to change notification settings - Fork 259
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Layered turret top rendering #2769
Conversation
You can download the rebuilt assembly for this PR here: https://combatextended.lp-programming.com/CombatExtended-6262151456.zip |
You can download the rebuilt assembly for this PR here: https://combatextended.lp-programming.com/CombatExtended-6262187508.zip |
You can download the rebuilt assembly for this PR here: https://combatextended.lp-programming.com/CombatExtended-6626946018.zip |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Works in my testing, though we'll need some additional texture work done on some of our turrets for the animations.
Mothballing this, but preserving the branch. It broadly works in testing, but in the absence of someone doing the texture work for the various turret elements, it lacks a purpose. Additionally, the standard visual recoil is satisfactory--may revisit this if someone cares to create the textures. |
Additions
Render turret top in multiple layers, top base -> barrels *n -> top.
If multiple barrel is defined and the gun fires in burst, the barrels reciprocate in alternation.
Everything in a modextension, CombatExtended.TurretDrawExtension
TurretTopGraphicData: graphic data of whatever sprite above the barrels
Barrels: a list of barrels
each barrels consist of:
BarrelOffset: vector2 offset of this barrel
BarrelGraphicData: graphic data of this barrel
TurretBottomGraphicData: graphic data of whatever sprite below the barrels
Reasoning
90mm gun looks stupid with its gunshield reciprocating along with barrel.
Alternatives
Suffer.
Testing
Check tests you have performed: